import service from '.'

const departmentApi = {
    getAll(){
        return service.get('/admin/department');
    },
    addInfo(department){
        return service.post('/admin/department',department);
    },
    updateInfo(department){
        return service.put('/admin/department',department);
    },
    delInfo(id){
        return service.delete(`/admin/department/${id}`);
    },
    getById(id){
        return service.get(`/admin/department/${id}`);
    }
};

export default departmentApi;